package com.link2room.quintesson.controller.manager;

import com.link2room.common.dto.result.base.BaseResultDto;
import com.link2room.quintesson.dto.param.manager.TaobaoXroomtypeManagerParamDto;
import com.link2room.quintesson.facade.ITaobaoXroomtypeFacadeService;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * Created by VegetaKo on 2017/1/12.
 */
@RestController
@RequestMapping("/manager/OnlineTaobaoXroomtypes")
public class OnlineTaobaoXroomtypeManagerController {
    @Resource
    private ITaobaoXroomtypeFacadeService taobaoXroomtypeFacadeService;

    @RequestMapping(method= RequestMethod.PUT)
    public BaseResultDto upTaobaoXroomtypeList(
            @RequestBody TaobaoXroomtypeManagerParamDto taobaoXroomtypeManagerParamDto
    )throws Exception{
        taobaoXroomtypeFacadeService.upTaobaoXroomtypeList(taobaoXroomtypeManagerParamDto);
        BaseResultDto l2rRs=new BaseResultDto();
        l2rRs.setResultCode(0);
        return l2rRs;
    }

    @RequestMapping(value = "/OnlineTaobaoXroomtype",method= RequestMethod.PUT)
    public BaseResultDto upTaobaoXroomtype(
            @RequestBody TaobaoXroomtypeManagerParamDto taobaoXroomtypeManagerParamDto
    )throws Exception{
        taobaoXroomtypeFacadeService.upTaobaoXroomtype(taobaoXroomtypeManagerParamDto);
        BaseResultDto l2rRs=new BaseResultDto();
        l2rRs.setResultCode(0);
        return l2rRs;
    }
}
